package com.witdata.rabbit.producer;

import lombok.RequiredArgsConstructor;
import org.springframework.amqp.rabbit.core.RabbitTemplate;
import org.springframework.stereotype.Component;

@Component
@RequiredArgsConstructor
public class PingProducer {
    private final RabbitTemplate rabbitTemplate;

    public void send() {
        rabbitTemplate.convertAndSend("hello", "你好");
    }

}



